﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package net.wooga.pets.views.components.sunface.states {
    import net.wooga.pets.views.components.sunface.*;
    import net.wooga.pets.utils.timeline.*;

    public class SunFaceTalking extends SunFaceBaseState implements ISunFaceState {

        private static const DEFAULT_FRAME_LABEL:String = "chating";

        public function SunFaceTalking(_arg1:SunFaceStateManager, _arg2:SequenceBasedStatesTimeline){
            super(_arg1, _arg2);
        }
        override public function initiate():void{
            timeline.gotoAndStop(DEFAULT_FRAME_LABEL);
        }
        override public function talk():void{
            playFromLabel(DEFAULT_FRAME_LABEL);
        }
        override public function idle():void{
        }
        override public function click():void{
        }
        override public function stop():void{
            this.interrupt();
            this.context.currentState = this.context.defaultState;
        }
        override protected function onTimelineAnimationFinished(_arg1:String):void{
            if (_arg1 == DEFAULT_FRAME_LABEL){
                playFromLabel(DEFAULT_FRAME_LABEL);
            };
        }

    }
}//package net.wooga.pets.views.components.sunface.states 
